#coding=utf-8
import UserAgent
import GetIP
import os
import time

totalTimes = 2
idx = 0
url = "http://app.iwxiao.com"
while idx < totalTimes:
    idx += 1
    newIp = GetIP.getIp()
    print("newIp",newIp)
    vpn = newIp#"218.75.100.114:8080"
    ua = UserAgent.getpc()
    cmd = "start chrome.exe " + url +" --proxy-server=" + vpn + " --incognito " + ua
    print("", cmd)
    os.system(cmd)
    time.sleep(4)
    os.system("taskkill /f /t /im chrome.exe")


